adep

Learn about adep, we have the largest and most updated adep information on alibabacloud.com

Use arm-none-eabi-gcc to compile STM32F10x in Ubuntu

########################################################################export CC = arm-none-eabi-gccexport AS = arm-none-eabi-asexport LD = arm-none-eabi-ldexport OBJCOPY = arm-none-eabi-objcopyTOP=$(shell pwd)INC_FLAGS= -I $(TOP)/lib/CMSIS_200/CM3/CoreSupport/ \ -I $(TOP)/lib/CMSIS_200/CM3/DeviceSupport/ST/STM32F10x \ -I $(TOP)/lib/STM32F10x_StdPeriph_Driver/inc \ -I $(TOP)/srcexport CFLAGS= -W -Wall

"Bzoj4668-" and "the Cold War"

=500000+ -;7 intU[MAXN],H[MAXN],T[MAXN];8 intDEP[MAXN];9 intTim;Ten intans=0, preans=0, n,m; One A intFindintx) - { - while(X!=u[x]) x=U[x]; the returnx; - } - - voidGETDEP (intx) + { - if(u[x]==x) + { Adep[x]=0; at return; - } - ElseGETDEP (u[x]); -dep[x]=dep[u[x]]+1; - } - in intAskintXinty) - { to intret=-1; + GETDEP (x); - getdep (y); the if(dep[x]Dep[y]) swap (x, y); * while(dep[x]>Dep[y]) $ {P

"Kruscal" "minimum Spanning Tree" "Block Tree" bzoj3732 Network

[maxn1]; - structGraph - { - intv[maxn1],first[maxn1],next[maxn1],w[maxn1],en; - voidAddedge (Const inta,Const intb) in{v[++en]=b;next[en]=first[a];first[a]=en;} - voidAddedge (Const inta,Const intb,Const intc) to{v[++en]=b;w[en]=c;next[en]=first[a];first[a]=en;} + }; -Graph g[2]; the intFA[MAXN],DEP[MAXN],TOP[MAXN],SIZ[MAXN],SZ,MAXV[MAXN],W[MAXN]; * intn,m,q,x,y; $ voidMakeblock (intcur)Panax Notoginseng { - for(inti=g[0].first[cur];i;i=g[0].next[i]) the if(g[0].v[i]!=Fa[

Bzoj 2286 tree chain split +dfs sequence + virtual tree + Tree DP

=getchar ();} x*=F; - } -InlinevoidPut_int (LL x) - { in Charch[ -]; LL top=0; - if(x==0) ch[++top]='0'; to while(x) ch[++top]=x%Ten+'0', x/=Ten; + while(top) Putchar (ch[top--]); Putchar ('\ n'); - } the //================================================ * voidDFS1 (LL u) $ {Panax Notoginsengmark[u]=++tot;vis[u]=true; size[u]=1; - for(LL i=head[u];i!=-1; i=edge[i].next) the if(!vis[edge[i].to]) + { Adep[edge[i].

BZOJ3631[JLOI2014] Squirrel's new home

*2];intg[maxn],ess; - voidPeintFintt) { theEs[++ess]= (e) {t,g[f]}; g[f]=ess; Es[++ess]= (e) {f,g[t]}; g[t]=ess; - } - voidInit () {ess=0; Memset (G,0,sizeof(g));} - intN,fa[maxn],dep[maxn],go[maxn],pos[maxn],top[maxn],sz[maxn],sm[maxn],tot; + voidDFS1 (intXintf) { -sz[x]=1; + for(intI=G[X];I;I=ES[I].N)if(es[i].t!=f) { Adep[es[i].t]=dep[x]+1; fa[es[i].t]=x; atDFS1 (ES[I].T,X); sz[x]+=sz[es[i].t]; - } - } - voidDFS2 (intXintFintTP) { -Pos[x]=

POJ 3694 Tarjan Bridge +LCA

connects U, v Point, and then outputs the number of remaining bridges in the connected graph.Idea: Mark the bridge first Tarjan, then LCA to remove all the bridges on the path. Code:1#include 2#include 3#include 4#include 5#include 6#include 7#include 8#include Set>9#include Ten#include One using namespacestd; A - #defineN 100005 - the intN, M; - intDfn[n], low[n], time; - intDep[n]; - BOOLBrg[n]; + intFather[n]; - intBrg_num; + A structedge{ at intu, V, next; -}e[400005]; - - intCNT;

Determine if it is a Hamiltonian figure--hdu 5424

{ thescanf"%d%d",u,v); + G[u].push_back (v); - g[v].push_back (u); $ } $ intHead=0, cnt=0; - for(intI=1; i) - if(g[i].size () = =1) the { -Head=i;///find a starting pointWuyicnt++; the } - if(cnt>2)///If there are more than two points with a degree of 1 Wu { -Puts"NO"); About Continue; $ } -memset (Vis,0,sizeof(Vis)); - if(Head = =0) -Head=1;///no degree is 1, which is a ring

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.